<nav class="navbar navbar-dark bg-dark">
  <ul class="nav">
    <li class="nav-item"><a href="#" class="navbar-brand">Route</a></li>
    <li class="nav-item">
      <a class="nav-link" [routerLink]="['/']">主页</a>
    </li>
    <li class="nav-item">
      <a class="nav-link" [routerLink]="['/product']" [queryParams]="{id:1}">商品详情</a>
    </li>
    <li class="nav-item">
      <a class="nav-link" [routerLink]="[{outlets:{aux:['chat']}}]">打开聊天窗口</a>
    </li>
    <li class="nav-item">
      <a class="nav-link" [routerLink]="[{outlets:{aux:null}}]" >关闭聊天窗口</a>
    </li>
  </ul>
</nav>
<div class="container" style="margin-top:30px">
  <div class="row">
    <router-outlet></router-outlet>
    <router-outlet name="aux"></router-outlet>
  </div>
</div>

